<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<div class="bjui-pageContent">
    <form action="<%=request.getContextPath()%>/user/insert.do" data-toggle="validate" data-reload-navtab="true">
        <input type="hidden" name="flag" value="Y">
        <div class="pageFormContent" data-layout-h="0">
            <table class="table table-condensed table-hover" width="100%">
                <tbody>
                    <tr>
                        <td colspan="2">
                            <label class="control-label x100">姓名：</label>
                            <input type="text" name="realname" value="${user.realname}" data-rule="required" size="30">
                        </td>
                    </tr>
                    <tr>
                        <td colspan="2">
                            <label class="control-label x100">登录账号：</label>
                            <input type="text" name="username" value="${user.username}" data-rule="required" size="30">
                        </td>
                    </tr>
                     <tr>
                        <td colspan="2">
                            <label class="control-label x100">联系电话：</label>
                            <input type="text" name="phone" value="${user.phone}" size="30">
                        </td>
                    </tr>
                     <tr>
                        <td colspan="2">
                            <label class="control-label x100">所在部门：</label>
                            <input type="text" name="unitname" value="${user.unitname}" size="30">
                        </td>
                    </tr>
                     <tr>
                        <td colspan="2">
                            <label class="control-label x100">个人简介：</label>
                            <textarea  name="memo" cols="30" rows="4" >${user.memo}</textarea>
                        </td>
                    </tr>
                     <tr>
                        <td colspan="2">
                            <label class="control-label x100">分配角色：</label>
                            <c:forEach items="${role}" var="rl">
                              <label><input type="checkbox" name="role" id="role" value=${rl.ucode}/>${rl.uname}</label>
                            </c:forEach>
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
    </form>
</div>

<div class="bjui-pageFooter">
    <ul>
        <li><button type="button" class="btn-close" data-icon="close">关闭</button></li>
        <li><button type="submit" class="btn-default" data-icon="save">保存</button></li>
    </ul>
</div>
